<!DOCTYPE html>
<html>
	<head>
		<meta charset="utf-8">
		<title></title>
	</head>
	<body>
		<button type="button" onclick="test1()">测试alert</button>
		<button type="button" onclick="test2()">测试confirm</button>
		<button type="button" onclick="test3()">测试prompt</button>
		
		<script type="text/javascript">
			
			//1.alert
			
			function test1()
			{
				window.alert("你好");
				
			}
			function test2()
			{
				var result = confirm("你确定要删除吗？")
				if(result){
					alert("已经删除");
					
				}else{
					
					alert("取消删除");
				}
				
			}
			function test3()
			{
				var name = prompt("请输入你的名字");
				alert("你的名字是："+name);
				
			}
			
			
		</script>
	</body>
</html>
